#ifndef _PACK_H_
#define _PACK_H_

typedef struct unpack
{
//	int size;
//	char *version;
	char *pack_num;
	char *cmd_num;
//	char *name;
//	char *host;
	char *addition;
	struct sockaddr_in *addr;
}Unpack;

void init_packinfo();
void clean_packinfo();
void pack_008(char *pack);
void pack_010(char *pack, int i);
int pack_011(char *pack, char *filebuf, int i, int flen);
void pack_012(char *pack, int i);
void pack_014(char *pack, int i);
void pack_018(char *pack, int info);
void pack_020(char *pack, char *buf, int num);
void pack_021(char *pack, int sockfd);
void pack_023(char *pack, int busy);
void pack_024(char *pack, int sockfd);
void pack_025_data(char *pack, char *data, int sockfd);
void pack_028(char *pack, char *data, int sockfd, int srcsockfd);
void unpack_head(char *pack);
int unpack_009(char *pack, int sockfd);
int unpack_013(char *data, int sockfd);
void unpack_015(char *buf, int len, int sockfd);
void unpack_016(char *buf, int sockfd);
int unpack_017(char *buf, int sockfd);
int unpack_022(char *buf, int sockfd);
void unpack_027(char *sendbuf, char *buf, int sockfd);
void unpack_029(char *buf);
void init_seq();

extern Unpack pack_info;
extern unsigned long seq;

#endif